package com.wanxs.mall.product.service;

import com.wanxs.mall.common.service.CrudService;
import com.wanxs.mall.product.dto.CategoryDTO;
import com.wanxs.mall.product.entity.CategoryEntity;
import com.wanxs.mall.product.vo.Catalog2VO;

import java.util.List;
import java.util.Map;

/**
 * 商品三级分类
 *
 * @author wanxs 130001934@qq.com
 * @since 1.0.0 2023-09-01
 */
public interface CategoryService extends CrudService<CategoryEntity, CategoryDTO> {


    List<CategoryEntity> queryPageWithTree(Map<String, Object> params);

    void removeCategoryByIds(List<Long> ids);

    Long[] queryCatelogPath(Long catelogId);

    Long[] getCatelogPath(Long catelogId);

    void updateDetail(CategoryEntity dto);

    List<CategoryEntity> queryLevel1Categorys();

    Map<String, List<Catalog2VO>> getCatelog2JSON();

    Map<String, List<Catalog2VO>> getCatelog2JSON2();

    Map<String, List<Catalog2VO>> getCatelogJsonWithLock() throws InterruptedException;
}